package implementation;
/**
* <br><b>Node</b>s Represents component of the parse tree</br>
* <b>Abstract class</b>
* @author NextEpisode1
* @version 1.6
* @since 3/4/2011
*/
public abstract class Node {
	/**The string representation of the node content*/
	private String content;
	/** This node represents the node from the <b>left</b> side .If left is null then the nod is operand.*/
	private Node left;
	/** This node represents the node from the <b>right</b> side .If right is null then the nod is operand.*/
	private Node right;
	
	/**
	 * <b>Constructor</b>creates a node with a given string as content
	 */
	public Node(String val) {
		content=val;
	}
	public String getContent(){
		return content; 
	}
	
	public void setContent(String _content){
		content = _content; 
	}
	public Node getLeft() {
		return left;
	}

	public void setLeft(Node left) {
		this.left = left;
	}
	public Node getRight() {
		return right;
	}
	public void setRight(Node right) {
		this.right = right;
	}
	
	/**The computeDerivate is a abstract method <b>recursive & abstract </b>
	 * @return derived value of the expression */
	public abstract Double computeDerivate();
	/**The evalDerivate is a abstract method  <b>recursive & abstract </b>
	 * @return string representation of the derived computation*/
	public abstract String evalDerivate();
}
